import React, {Component} from 'react'
import {Card} from "primereact/card";
import SignDiaog from "../dialog/SignDiaog";
import {Dialog} from "primereact/dialog";

export default class Sign extends Component {
    constructor() {
        super();
        this.state = {}
        this.openDialog = this.openDialog.bind(this);
    }

    openDialog(event) {
        this.setState({
            visible: event,
        })
    }

    render() {
        return (
            <div>
                <Card>
                    <div onClick={() => this.setState({signVisible: true})}>
                        <i className="pi pi-calendar" style={{'fontSize': '6em'}}></i>
                        <div className="word">
                            <h2>签到</h2>
                            <h4>每天签到领奖</h4>
                        </div>
                    </div>
                </Card>
                <Dialog header="签到"
                        visible={this.state.signVisible}
                        onHide={() => this.setState({signVisible: false})}
                        width={700}
                        modal={true}>
                    <SignDiaog/>
                </Dialog>
            </div>

        )
    }
}